﻿@model List<MvcFrameStruct.Areas.User.Models.User>
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
}

<!DOCTYPE html>

<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <title>Index</title>
   
    <style>
        body {
        margin-top:5px;
        }
    </style>
</head>
<body>
    <input type="button" class="btn btn-default"  value="添加用户" />
    @Html.ActionLink("添加用户", "AddUser")
    <table class="table table-bordered table-hover">
        <tr class="text-center">
            <td>用户姓名</td>
            <td>出生日期</td>
            <td>性别</td>
            <td>操作</td>
        </tr>
        @foreach (var item in Model)
        {
            <tr class="text-center">
                <td>@item.Name</td>
                <td>@item.BirthDate</td>
                <td>
                    @if (item.UserSex == true)
                    {
                        @:男
                            }
                    else
                    {
                        @:女
                            }
                </td>
                <td>
                    @Html.ActionLink("删除", "Show", new { id = item.UserId,flag="Delete" })
                    &nbsp;
                    @Html.ActionLink("修改", "Show", new { id = item.UserId, flag = "Update" })
                </td>
            </tr>
        }
    </table>

</body>
</html>
